/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package br.com.biblioteca.conection;

import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;
import java.util.logging.Level;
import java.util.logging.Logger;

/**
 *
 * @author Andre
 */
public class CriaConexao {

    static String driver = "com.mysql.jdbc.Driver";
    static private String url = "jdbc:mysql://localhost:3306/biblioteca";
    static private String usuario = "root";
    static private String senha = "123";
   
    

    public static Connection getConexao() throws ClassNotFoundException, SQLException {
        Class.forName(driver);
        return DriverManager.getConnection(url, usuario, senha);
       
     

    }
}
